<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>Animation</title>
		<style type="text/css">
			.div {
				width: 100px;
				height: 100px;
				background-color: red;
				animation: translate 2s linear infinite;
			}

			/* 关键帧 */
			@keyframes translate {
				25% {
					margin-left: 200px;
				}

				50% {
					margin-top: 200px;
					margin-bottom: 200px;
				}

				75% {
					margin-top: 200px;
					margin-left: 0px;
				}

				100% {
					margin-left: 0px;
					margin-left: 0px;
				}
			}
		</style>
	</head>
	<body>
		<div class="div"></div>
	</body>
</html>
